package nl.han.ica.ap.searchengine.client;

import java.util.ArrayList;
import java.util.Arrays;
import java.util.List;

/**
 * Represent a query to be processed by the search engine
 * 
 * @author A.J. Janssen, ...
 * @version 0.1
 *
 */
public class SearchQuery 
{
	private final List<String> keywords = new ArrayList<String>();
	
	public SearchQuery(List<String> keywords)
	{
		this.keywords.addAll(keywords);
	}
	
	//TODO: note: this simple splits a String on every whitespace, ignores quotes
	public SearchQuery(String query)
	{
		keywords.addAll(Arrays.asList(query.split(" ")));
	}
	
	public List<String> getKeywords() {
		return keywords;
	}
}
